﻿

<!DOCTYPE html>
<html lang="en">
    <head>
        <meta charset="utf-8">
        <title>异步更新队列</title>
		
		<script src="vue.js">
<script type="text/javascript">
<!--
	
//-->
</script>		

    </head>
    <body class="docs"> 

<div id="app">
  <example></example>
  
</div>
	
    </body>
	
<script type="text/javascript">
<!--

Vue.component('example', {
  template: '<span>{{ message }}</span>',
  data: function () {
    return {
      message: 'not updated'
    }
  },
  methods: {
    updateMessage: function () {
      this.message = 'updated'
      console.log(this.$el.textContent) // => 'not updated'
      this.$nextTick(function () {
        console.log(this.$el.textContent) // => 'updated'
      })
    }
  }
})

// 创建根实例
var vm = new Vue({
  el: '#app'
})

//怎么改变component的值?

</script>
	
</html>
